package com.biz.primus.model.coupon.vo.couponType;

import com.biz.primus.base.exception.utils.AssertUtils;
import com.biz.primus.model.coupon.exceptions.CouponTypeExceptionType;
import com.biz.primus.model.coupon.interfaces.IModelIdentifiable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.sql.Timestamp;
import java.util.Objects;
import lombok.Getter;
import lombok.Setter;

/**
 * 优惠券类型详情Vo
 *
 * @author david-liu
 */
@Getter
@Setter
@ApiModel(description = "优惠券类型详情")
public class CouponTypeDetailVo extends CouponTypeVo implements IModelIdentifiable<Long> {

    private static final long serialVersionUID = 6613031905932626637L;

    @ApiModelProperty(value = "id", notes = "优惠券类型ID")
    private Long id;

    @ApiModelProperty(value = "createTimestamp", notes = "创建时间")
    private Timestamp createTimestamp;

    @Override
    public void validate() {
        AssertUtils.notNull(Objects.nonNull(id), CouponTypeExceptionType.PARAMETER_ILLEGAL, new Object[]{"ID不能为空"});
        super.validate();
    }
}
